<script setup lang='ts'>
import { ref } from 'vue';
import thisUserData from "@/components/pc/thisUserData.vue";
import { data1 ,data2} from "@/typeApi/userDataApi";
const data = ref(['饰品', '五金', '美妆', '园艺', '家居', '杂货铺'])
const isI = ref<number>(0)
const getI = (e: number) => {
    isI.value = e
}
</script>

<template>
    <div class="content">
        <div class="title">
            <img class="hr" src="../../assets/img/下载 (2).png" alt="">
            <h1>成功案例</h1>
            <img class="hr" src="../../assets/img/下载 (2).png" alt="">
        </div>
        <p>为了保护客户隐私，不便透露客户名称</p>
        <div class="select">
            <div :class="['selectData', isI === index ? 'newColor' : '']" @click="getI(index)"
                v-for="(i, index) in data" :key="index">
                {{ i }}
            </div>
        </div>
    </div>
    <thisUserData :imgData = data1[isI] :isI :imgDataText = data2[isI]></thisUserData>
</template>

<style scoped>
@import url(../../assets/style/userData.css);
</style>